import { request } from '../request'
export default {
  API_LOGIN_MOBILE_POST(data = {}) {
    // code=${data.code}&nickname=${data.nickName}&avatar=${data.avatarUrl}&phone=${data.phone}
    return request({
      url: `/api/sms/send`,
      method: 'post',
      data
    })
  },
  API_LOGIN_WX_POST(params = {}) {
    return request({
      url: `api/member/wxlogin`,
      method: 'post',
      data: params
    })
  },
  //获取用户信息 -- 已废弃
  API_GET_USER_PROFILE_POST(params = {}) {
    return request({
      url: `api/member/getUserProfile`,
      method: 'post',
      data: params
    })
  },
  //获取用户信息
  API_MEMBER_GET_USER_INFO_POST(params = {}) {
    return request({
      url: `api/member/getUserInfo`,
      method: 'post',
      data: params
    })
  },
  //获取用户手机号
  API_GET_USER_PHONE_POST(params = {}) {
    return request({
      url: `api/member/getPhoneNumber`,
      method: 'post',
      data: params
    })
  },
  //获取用户协议
  API_GET_USER_AGREEMENT(data = {}) {
    return request({
      url: `api/index/useragreement`,
      method: 'get',
      data
    })
  },
  //获取隐私协议
  API_GET_PRIVACY_AGREEMENT(data = {}) {
    return request({
      url: `api/index/privacyagreement`,
      method: 'get',
      data
    })
  },
  //获取服务协议
  API_GET_SERVICE_AGREEMENT(data = {}) {
    return request({
      url: `api/index/serviceagreement`,
      method: 'get',
      data
    })
  },
  //支付协议
  API_GET_PAYMENT_AGREEMENT(data = {}) {
    return request({
      url: `aapi/index/paymentprotocol`,
      method: 'get',
      data
    })
  },
  //退出登录
  API_LOGOUT_POST(params = {}) {
    return request({
      url: `api/member/logout`,
      method: 'post',
      data:params
    })
  }
}
